package com.crm.model.pojo;

import java.io.Serializable;
import javax.persistence.*;
import java.math.BigDecimal;


/**
 * The persistent class for the orderdetails database table.
 * 
 */
@Entity
@Table(name="orderdetails")
@NamedQuery(name="Orderdetail.findAll", query="SELECT o FROM Orderdetail o")
public class Orderdetail implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	private String orderdetailsid;

	private BigDecimal orderdetailsmoney;

	private int orderdetailsnumber;

	private String orderstate;

	//bi-directional many-to-one association to Order
	@ManyToOne
	@JoinColumn(name="orderid")
	private Order order;

	//bi-directional many-to-one association to Product
	@ManyToOne
	@JoinColumn(name="pid")
	private Product product;

	public Orderdetail() {
	}

	public String getOrderdetailsid() {
		return this.orderdetailsid;
	}

	public void setOrderdetailsid(String orderdetailsid) {
		this.orderdetailsid = orderdetailsid;
	}

	public BigDecimal getOrderdetailsmoney() {
		return this.orderdetailsmoney;
	}

	public void setOrderdetailsmoney(BigDecimal orderdetailsmoney) {
		this.orderdetailsmoney = orderdetailsmoney;
	}

	public int getOrderdetailsnumber() {
		return this.orderdetailsnumber;
	}

	public void setOrderdetailsnumber(int orderdetailsnumber) {
		this.orderdetailsnumber = orderdetailsnumber;
	}

	public String getOrderstate() {
		return this.orderstate;
	}

	public void setOrderstate(String orderstate) {
		this.orderstate = orderstate;
	}

	public Order getOrder() {
		return this.order;
	}

	public void setOrder(Order order) {
		this.order = order;
	}

	public Product getProduct() {
		return this.product;
	}

	public void setProduct(Product product) {
		this.product = product;
	}

}